package com.dries.portal.module.portal.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * 用户评价回复表
 * 
 * @author dries
 * @email samphsanie@gmail.com
 * @date 2020-08-07 13:37:45
 */
@Data
@TableName("xx_discuss_reply")
public class DiscussReply implements Serializable {
	private static final long serialVersionUID = 1L;

	/**
	 * 用户ID
	 */
	@TableId(type = IdType.AUTO)
	private Integer id;
	/**
	 * 评论父ID
	 */
	@JsonSerialize(using = ToStringSerializer.class)
	private Integer parentId;
	/**
	 * 评价详情关联字段
	 */
	private Integer discussDetailId;
	/**
	 * 回复
	 */
	private String discussReply;
	/**
	 * 用户点赞数
	 */
	private Integer replyLikes;
	/**
	 * 用户ID
	 */
	@JsonSerialize(using = ToStringSerializer.class)
	private Long userId;
	/**
	 * 用户头像
	 */
	private String userAvatar;
	/**
	 * 用户昵称
	 */
	private String userName;
	/**
	 * 创建时间
	 */
	private Date createTime;
	/**
	 * 修改时间
	 */
	private Date modified;

	@TableField(exist = false)
	private List<DiscussReply> replies;

}
